<?php

class LevelDao{
	
	public function getLevel($id_level){
		$db=Database::getInstance();
        $con=$db->getConnection(1);

        $query="SELECT * FROM ref_level WHERE id_level='$id_level'";

        $result=$con->prepare($query);
        $result->execute();

        if($result->rowCount()==1){
            $data=$result->fetch();
            return $data['nama_level'];
        }

        return false;
	}


}

class Level{
	
	var $id_level;
	var $nama_level;

}


?>